Subject: Transmission Group Effective Capacity and Delay

From: "jim (j.) cobban" <[email-masked]>
Date: Fri, 26 Apr 1996 13:14:00 -0400

Just in case you wanted a convenient list of ALL of the values of TG
effective capacity and delay, here is a table.  It is generated by the C
program which is appended to the end of this message:

Code  Effective Capacity (b/s)    Propagation Delay (sec)
00           150 b/s              0.000,000 sec
01           170 b/s              0.000,000 sec
02           190 b/s              0.000,000 sec
03           210 b/s              0.000,000 sec
04           230 b/s              0.000,000 sec
05           240 b/s              0.000,000 sec
06           260 b/s              0.000,000 sec
07           280 b/s              0.000,000 sec
08           300 b/s              0.000,001 sec
09           340 b/s              0.000,001 sec
0A           380 b/s              0.000,001 sec
0B           410 b/s              0.000,001 sec
0C           450 b/s              0.000,001 sec
0D           490 b/s              0.000,001 sec
0E           530 b/s              0.000,001 sec
0F           560 b/s              0.000,001 sec
10           600 b/s              0.000,002 sec
11           680 b/s              0.000,002 sec
12           750 b/s              0.000,002 sec
13           830 b/s              0.000,002 sec
14           900 b/s              0.000,003 sec
15           980 b/s              0.000,003 sec
16          1050 b/s              0.000,003 sec
17          1130 b/s              0.000,003 sec
18          1200 b/s              0.000,004 sec
19          1350 b/s              0.000,004 sec
1A          1500 b/s              0.000,005 sec
1B          1700 b/s              0.000,005 sec
1C          1800 b/s              0.000,006 sec
1D          2000 b/s              0.000,006 sec
1E          2100 b/s              0.000,007 sec
1F          2300 b/s              0.000,007 sec
20          2400 b/s              0.000,008 sec
21          2700 b/s              0.000,009 sec
22          3000 b/s              0.000,010 sec
23          3300 b/s              0.000,011 sec
24          3600 b/s              0.000,012 sec
25          3900 b/s              0.000,013 sec
26          4200 b/s              0.000,014 sec
27          4500 b/s              0.000,015 sec
28          4800 b/s              0.000,016 sec
29          5400 b/s              0.000,018 sec
2A          6000 b/s              0.000,020 sec
2B          6600 b/s              0.000,022 sec
2C          7200 b/s              0.000,024 sec
2D          7800 b/s              0.000,026 sec
2E          8400 b/s              0.000,028 sec
2F          9000 b/s              0.000,030 sec
30          9600 b/s              0.000,032 sec
31         10800 b/s              0.000,036 sec
32         12000 b/s              0.000,040 sec
33         13200 b/s              0.000,044 sec
34         14400 b/s              0.000,048 sec
35         15600 b/s              0.000,052 sec
36            17 Kb/s             0.000,056 sec
37            18 Kb/s             0.000,060 sec
38            19 Kb/s             0.000,064 sec
39            22 Kb/s             0.000,072 sec
3A            24 Kb/s             0.000,080 sec
3B            26 Kb/s             0.000,088 sec
3C            29 Kb/s             0.000,096 sec
3D            31 Kb/s             0.000,104 sec
3E            34 Kb/s             0.000,112 sec
3F            36 Kb/s             0.000,120 sec
40            38 Kb/s             0.000,128 sec
41            43 Kb/s             0.000,144 sec
42            48 Kb/s             0.000,160 sec
43            53 Kb/s             0.000,176 sec
44            58 Kb/s             0.000,192 sec
45            62 Kb/s             0.000,208 sec
46            67 Kb/s             0.000,224 sec
47            72 Kb/s             0.000,240 sec
48            77 Kb/s             0.000,256 sec
49            86 Kb/s             0.000,288 sec
4A            96 Kb/s             0.000,320 sec
4B           106 Kb/s             0.000,350 sec
4C           115 Kb/s             0.000,380 sec
4D           125 Kb/s             0.000,420 sec
4E           134 Kb/s             0.000,450 sec
4F           144 Kb/s             0.000,480 sec
50           154 Kb/s             0.000,510 sec
51           170 Kb/s             0.000,580 sec
52           190 Kb/s             0.000,640 sec
53           210 Kb/s             0.000,700 sec
54           230 Kb/s             0.000,770 sec
55           250 Kb/s             0.000,830 sec
56           270 Kb/s             0.000,900 sec
57           290 Kb/s             0.000,960 sec
58           310 Kb/s             0.001,020 sec
59           350 Kb/s             0.001,150 sec
5A           380 Kb/s             0.001,280 sec
5B           420 Kb/s             0.001,410 sec
5C           460 Kb/s             0.001,540 sec
5D           500 Kb/s             0.001,660 sec
5E           540 Kb/s             0.001,800 sec
5F           580 Kb/s             0.001,900 sec
60           610 Kb/s             0.002     sec
61           690 Kb/s             0.002,300 sec
62           770 Kb/s             0.002,600 sec
63           840 Kb/s             0.002,800 sec
64           920 Kb/s             0.003,100 sec
65          1000 Kb/s             0.003,300 sec
66          1080 Kb/s             0.003,600 sec
67          1150 Kb/s             0.003,800 sec
68          1230 Kb/s             0.004,100 sec
69          1380 Kb/s             0.004,600 sec
6A          1540 Kb/s             0.005,100 sec
6B          1700 Kb/s             0.005,600 sec
6C          1800 Kb/s             0.006,100 sec
6D          2000 Kb/s             0.006,700 sec
6E          2200 Kb/s             0.007,200 sec
6F          2300 Kb/s             0.007,700 sec
70          2500 Kb/s             0.008,200 sec
71          2800 Kb/s             0.009,200 sec
72          3100 Kb/s             0.010,200 sec
73          3400 Kb/s             0.011,300 sec
74          3700 Kb/s             0.012,300 sec
75          4000 Kb/s             0.013,300 sec
76          4300 Kb/s             0.014,300 sec
77          4600 Kb/s             0.015,400 sec
78          4900 Kb/s             0.016     sec
79          5500 Kb/s             0.018     sec
7A          6100 Kb/s             0.020     sec
7B          6800 Kb/s             0.023     sec
7C          7400 Kb/s             0.025     sec
7D          8000 Kb/s             0.027     sec
7E          8600 Kb/s             0.029     sec
7F          9200 Kb/s             0.031     sec
80          9800 Kb/s             0.033     sec
81         11100 Kb/s             0.037     sec
82         12300 Kb/s             0.041     sec
83         13500 Kb/s             0.045     sec
84         14700 Kb/s             0.049     sec
85         16000 Kb/s             0.053     sec
86            17 Mb/s             0.057     sec
87            18 Mb/s             0.061     sec
88            20 Mb/s             0.066     sec
89            22 Mb/s             0.074     sec
8A            25 Mb/s             0.082     sec
8B            27 Mb/s             0.090     sec
8C            29 Mb/s             0.098     sec
8D            32 Mb/s             0.106     sec
8E            34 Mb/s             0.115     sec
8F            37 Mb/s             0.123     sec
90            39 Mb/s             0.131     sec
91            44 Mb/s             0.147     sec
92            49 Mb/s             0.160     sec
93            54 Mb/s             0.180     sec
94            59 Mb/s             0.200     sec
95            64 Mb/s             0.210     sec
96            69 Mb/s             0.230     sec
97            74 Mb/s             0.250     sec
98            79 Mb/s             0.260     sec
99            88 Mb/s             0.290     sec
9A            98 Mb/s             0.330     sec
9B           108 Mb/s             0.360     sec
9C           118 Mb/s             0.390     sec
9D           128 Mb/s             0.430     sec
9E           138 Mb/s             0.460     sec
9F           147 Mb/s             0.490     sec
A0           157 Mb/s             0.520     sec
A1           180 Mb/s             0.590     sec
A2           200 Mb/s             0.660     sec
A3           220 Mb/s             0.720     sec
A4           240 Mb/s             0.790     sec
A5           260 Mb/s             0.850     sec
A6           280 Mb/s             0.920     sec
A7           290 Mb/s             0.980     sec
A8           310 Mb/s             1.050     sec
A9           350 Mb/s             1.180     sec
AA           390 Mb/s             1.310     sec
AB           430 Mb/s             1.440     sec
AC           470 Mb/s             1.570     sec
AD           510 Mb/s             1.700     sec
AE           550 Mb/s             1.800     sec
AF           590 Mb/s             2         sec
B0           630 Mb/s             2.100     sec
B1           710 Mb/s             2.400     sec
B2           790 Mb/s             2.600     sec
B3           870 Mb/s             2.900     sec
B4           940 Mb/s             3.100     sec
B5          1020 Mb/s             3.400     sec
B6          1100 Mb/s             3.700     sec
B7          1180 Mb/s             3.900     sec
B8          1260 Mb/s             4.200     sec
B9          1420 Mb/s             4.700     sec
BA          1570 Mb/s             5.200     sec
BB          1700 Mb/s             5.800     sec
BC          1900 Mb/s             6.300     sec
BD          2000 Mb/s             6.800     sec
BE          2200 Mb/s             7.300     sec
BF          2400 Mb/s             7.900     sec
C0          2500 Mb/s             8.400     sec
C1          2800 Mb/s             9.400     sec
C2          3100 Mb/s            10.500     sec
C3          3500 Mb/s            11.500     sec
C4          3800 Mb/s            12.600     sec
C5          4100 Mb/s            13.600     sec
C6          4400 Mb/s            14.700     sec
C7          4700 Mb/s            15.700     sec
C8          5000 Mb/s            17         sec
C9          5700 Mb/s            19         sec
CA          6300 Mb/s            21         sec
CB          6900 Mb/s            23         sec
CC          7500 Mb/s            25         sec
CD          8200 Mb/s            27         sec
CE          8800 Mb/s            29         sec
CF          9400 Mb/s            31         sec
D0         10100 Mb/s            34         sec
D1         11300 Mb/s            38         sec
D2         12600 Mb/s            42         sec
D3         13800 Mb/s            46         sec
D4         15100 Mb/s            50         sec
D5            16 Gb/s            55         sec
D6            18 Gb/s            59         sec
D7            19 Gb/s            63         sec
D8            20 Gb/s            67         sec
D9            23 Gb/s            75         sec
DA            25 Gb/s            84         sec
DB            28 Gb/s            92         sec
DC            30 Gb/s           101         sec
DD            33 Gb/s           109         sec
DE            35 Gb/s           117         sec
DF            38 Gb/s           126         sec
E0            40 Gb/s           134         sec
E1            45 Gb/s           151         sec
E2            50 Gb/s           170         sec
E3            55 Gb/s           180         sec
E4            60 Gb/s           200         sec
E5            65 Gb/s           220         sec
E6            70 Gb/s           230         sec
E7            75 Gb/s           250         sec
E8            81 Gb/s           270         sec
E9            91 Gb/s           300         sec
EA           101 Gb/s           340         sec
EB           111 Gb/s           370         sec
EC           121 Gb/s           400         sec
ED           131 Gb/s           440         sec
EE           141 Gb/s           470         sec
EF           151 Gb/s           500         sec
F0           160 Gb/s           540         sec
F1           180 Gb/s           600         sec
F2           200 Gb/s           670         sec
F3           220 Gb/s           740         sec
F4           240 Gb/s           810         sec
F5           260 Gb/s           870         sec
F6           280 Gb/s           940         sec
F7           300 Gb/s         1,010         sec
F8           320 Gb/s         1,070         sec
F9           360 Gb/s         1,210         sec
FA           400 Gb/s         1,340         sec
FB           440 Gb/s         1,480         sec
FC           480 Gb/s         1,600         sec
FD           520 Gb/s         1,700         sec
FE           560 Gb/s         1,900         sec
FF           600 Gb/s         2,000         sec

/************************************************************************/
/*									*/
/*	APPN Transmission Group Effective Capacity calculation		*/
/*									*/
/************************************************************************/

#include <stdio.h>
#include <ctype.h>
#include <math.h>


void main()

{
    double	effcap;
    int		propdly;
    int		exp;
    int		mantissa;
    int		f;
    double	effres, effrnd;
    int		propres, proprnd;
    char	buffer[24];

    printf("Code  Effective Capacity (b/s)    Propagation Delay (sec)\n");

    for(f=0; f<=255; f++)
    {
	exp	= f >> 3;
	mantissa= (f & 7) + 8;
	if (exp > 4)
	{
	    propdly =  mantissa << (exp - 4);
	    effcap = (double)(300 * mantissa)  * (1 << (exp - 4));
	}
	else
	if (exp < 4)
	{
	    propdly = mantissa >> (4 - exp);
	    effcap = (300 * mantissa) >> (4 - exp);
	}
	else
	{
	    propdly =  mantissa;
	    effcap = 300 * mantissa;
	}

	/* calculate the largest power of 10 which is less than 1/160th	*/
	/* of the effective capacity in bits per second.  This is the	*/
	/* resolution of the number and is used to suppress		*/
	/* insignificant low order digits.				*/

	for(effres = 1.0; effres < (effcap/160); effres *= 10.0);

	/* round the effective capacity to a value which is a multiple	*/
	/* of the decimal resolution					*/

	effrnd	= effres/2;
	effcap	= floor((effcap + effrnd)/effres) * effres;

	if (effres < 1000.0)
	  printf("%02X        %6.0f b/s   ",
		 f,
		 effcap);
	else
	if (effres < 1000000.0)
	{
	  printf("%02X        %6.0f Kb/s  ",
		 f,
		 effcap/1000.0);
	}
	else
	if (effres < 1000000000.0)
	  printf("%02X        %6.0f Mb/s  ",
		 f,
		 effcap/1000000.0);
	else
	  printf("%02X        %6.0f Gb/s  ",
		 f,
		 effcap/1000000000.0);

	/* calculate the largest power of 10 which is less than 1/160th	*/
	/* of the delay in micro-seconds.  This is the resolution of the*/
	/* number and is used to suppress insignificant low order digits.*/

	for(propres = 1; propres < (propdly/160); propres *= 10);

	/* round the delay to a value which is a multiple of		*/
	/* the decimal resolution					*/

	proprnd	= propres/2;
	propdly	= ((propdly + proprnd)/propres) * propres;

	/* print the value as a number of seconds, with 6 digits after	*/
	/* the decimal point, and then format it with inserted commas.	*/

	sprintf(buffer, "%16.6f", (double)propdly/1000000.0);
	/* buffer now contains   ZZZZZZZZ9.999999			*/
	/* we want to take it to ZZZZ,ZZ9.999,999 as appropriate	*/
	if (strncmp(buffer+2, "    ", 4))
	{		/* significant digits in the thousands range	*/
	  buffer[0]	= buffer[2];
	  buffer[1]	= buffer[3];
	  buffer[2]	= buffer[4];
	  buffer[3]	= buffer[5];
	  buffer[4]	= ',';
	}
	buffer[5]	= buffer[6];
	buffer[6]	= buffer[7];
	buffer[7]	= buffer[8];
	if (strncmp(buffer+10, "000000", 6) | (propdly < 1))
	{		/* non-zero digits in fractional part		*/
	  buffer[8]	= '.';
	  buffer[9]	= buffer[10];
	  buffer[10]	= buffer[11];
	  buffer[11]	= buffer[12];
	  if (strncmp(buffer+13, "000", 3) | (propdly < 1))
	  {		/* non-zero digits in microseconds part		*/
	    buffer[12]	= ',';
	  }		/* non-zero digits in microseconds part		*/
	  else
	    strcpy(buffer + 12, "    ");/* delete off microseconds	*/
	}		/* non-zero digits in fractional part		*/
	else
	  strcpy(buffer + 8, "        ");/* delete off fractional part	*/
	printf("    %s sec\n",
	       buffer);
    }		/* end of for loop 				*/

}		/*	end of main					*/